package com.neuedu.corejava.ch2.homework;
import java.util.Random;

// 已知a,b均是整型变量，写出将a,b两个变量中的值互换的程序。（知识点：变量和运算符综合应用）

public class test1 {
	public static void main(String[] args) {
		int a = new Random().nextInt(100);
		int b = new Random().nextInt(100);
		System.out.println("交换前"+a + "," + b);
		int temp = a;
		a = b;
		b = temp;
		System.out.println("交换后"+a + "," + b);
		System.out.println("--------------------------------");
	}
}
